package com.nanfangzhe.shirodemo.service.impl;

import com.nanfangzhe.shirodemo.entity.URole;
import com.nanfangzhe.shirodemo.entity.UUserRole;
import com.nanfangzhe.shirodemo.mapper.URoleMapper;
import com.nanfangzhe.shirodemo.service.URoleService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * <p>
 * 角色表 服务实现类
 * </p>
 *
 * @author nanfangzhe
 * @since 2020-11-25
 */
@Service
public class URoleServiceImpl extends ServiceImpl<URoleMapper, URole> implements URoleService {
	@Autowired
	private URoleMapper dao;
	
	@Override
	public URole getRole(int id) {
		QueryWrapper<URole> wrapper = new QueryWrapper<URole>();
		wrapper.eq("id", id);
		return dao.selectOne(wrapper);
	}

}
